<?php

/*
|--------------------------------------------------------------------------
| Routes File
|--------------------------------------------------------------------------
|
| Here is where you will register all of the routes in an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/


/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| This route group applies the "web" middleware group to every route
| it contains. The "web" middleware group is defined in your HTTP
| kernel and includes session state, CSRF protection, and more.
|
*/

    Route::get('/', 'IndexController@login');
    Route::get('login', 'IndexController@login');
    Route::post('login/submit', 'IndexController@submitLoginData');
    Route::group(['middleware' => 'auth'], function () {
        Route::get('index', 'IndexController@index');
        Route::get('policy', 'IndexController@policy');
        Route::get('guidance', 'IndexController@guidance');
        Route::get('information', 'IndexController@information');
        Route::get('technical', 'IndexController@technical');
        Route::get('download_list', 'IndexController@downloadList');
        Route::get('news/{id}', 'IndexController@newsDetail');
        Route::get('download/energy/audit', 'IndexController@downloadEnergyAudit');
        Route::get('download/file', 'IndexController@downloadFileByName');
    });
